package com.lyj.springcloud.entities;

public class Person {

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    private String sex;

    public Person(String sex) {
        this.sex = sex;
        System.out.println("父类有参构造函数执行。。。");
    }

    public Person() {
        System.out.println("父类无参构造函数执行。。。");
    }

    public void work() {
        System.out.println("人类正在工作。。。。" );
        sleep();
    }

    public void sleep() {
        System.out.println("人类要睡觉。。。。。");
    }
}
